<%@ page import="static com.test.ws.s1.utils.Res.fileUrl" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%--
  Created by IntelliJ IDEA.
  User: M1523
  Date: 2025/3/21
  Time: 16:00
  To change this template use File | Settings | File Templates.
--%>
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" isELIgnored="false" %>
<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <title>自然风光 - 旅游分类详情</title>
    <style>
        body {
            font-family: '楷体', 'KaiTi', sans-serif; /* 修改字体为楷体 */
            background-color: #f4f4f4;
            display: flex;
            justify-content: center;
            align-items: flex-start;
            height: 100vh;
            margin: 0;
            background-image: url("${pageContext.request.contextPath}/images/981.jpg");
            background-size: cover;
            background-position: center;
        }
        .container {
            background-color: rgba(255, 255, 255, 0.5); /* 半透明背景 */
            padding: 30px;
            border-radius: 10px;
            box-shadow: 0 0 20px rgba(0, 0, 0, 0.2);
            width: 80%;
            max-width: 1200px;
            margin-top: 20px;
        }
        .container h2 {
            margin-bottom: 20px;
            color: #333;
            text-align: center;
        }
        .category-details {
            display: grid;
            grid-template-columns: 1fr; /* 单列布局 */
            gap: 20px;
        }
        .category-item {
            background-color: #fff;
            padding: 20px;
            border-radius: 5px;
            box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
            text-align: center;
            transition: transform 0.3s, box-shadow 0.3s;
            text-decoration: none; /* 去掉下划线 */
            color: inherit; /* 继承父元素的颜色 */
        }
        .category-item:hover {
            transform: translateY(-5px);
            box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
        }
        .category-item img {
            max-width: 100%;
            height: auto;
            border-radius: 5px;
            margin-bottom: 10px;
        }
        .category-item h3 {
            margin: 10px 0;
            color: #333;
        }
        .category-item p {
            color: #666;
            font-size: 14px;
        }
        .back-button {
            background-color: #28a745;
            color: white;
            padding: 10px 20px;
            border: none;
            border-radius: 5px;
            cursor: pointer;
            transition: background-color 0.3s;
            display: inline-block;
            margin-top: 20px;
        }
        .back-button:hover {
            background-color: #218838;
        }
        .back-button:active {
            background-color: #1e7e34;
        }
    </style>
</head>
<body>
<div class="container">
    <h2>自然风光 - 旅游分类详情</h2>
    <div class="category-details">
        <c:forEach items="${xianluFenLei}" var="classIf">
            <a href="${pageContext.request.contextPath}/lxxq" class="category-item">
                <img src="<%=fileUrl%>${classIf.route_img}" alt="自然风光详情1">
                <h3>${classIf.route_name}</h3>
                <p>${classIf.route_js}</p>
            </a>
        </c:forEach>
    </div>
    <a href="${pageContext.request.contextPath}/zhuye" class="back-button">返回主页面</a>
</div>
</body>
</html>
